<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
	<title>Get data frame analytics jobs statistics API | ElasticSearch 7.7 权威指南中文版</title>
	<meta name="keywords" content="ElasticSearch 权威指南中文版, elasticsearch 7, es7, 实时数据分析，实时数据检索" />
    <meta name="description" content="ElasticSearch 权威指南中文版, elasticsearch 7, es7, 实时数据分析，实时数据检索" />
    <!-- Give IE8 a fighting chance -->
    <!--[if lt IE 9]>
    <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script>
    <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
    <![endif]-->
	<link rel="stylesheet" type="text/css" href="../static/styles.css" />
	<script>
	var _link = 'get-dfanalytics-stats.html';
    </script>
</head>
<body>
<div class="main-container">
    <section id="content">
        <div class="content-wrapper">
            <section id="guide" lang="zh_cn">
                <div class="container">
                    <div class="row">
                        <div class="col-xs-12 col-sm-8 col-md-8 guide-section">
                            <div style="color:gray; word-break: break-all; font-size:12px;">原英文版地址: <a href="https://www.elastic.co/guide/en/elasticsearch/reference/7.7/get-dfanalytics-stats.html" rel="nofollow" target="_blank">https://www.elastic.co/guide/en/elasticsearch/reference/7.7/get-dfanalytics-stats.html</a>, 原文档版权归 www.elastic.co 所有<br/>本地英文版地址: <a href="../en/get-dfanalytics-stats.html" rel="nofollow" target="_blank">../en/get-dfanalytics-stats.html</a></div>
                        <!-- start body -->
                  <div class="page_header">
<strong>重要</strong>: 此版本不会发布额外的bug修复或文档更新。最新信息请参考 <a href="https://www.elastic.co/guide/en/elasticsearch/reference/current/index.html" rel="nofollow">当前版本文档</a>。
</div>
<div id="content">
<div class="breadcrumbs">
<span class="breadcrumb-link"><a href="index.html">Elasticsearch Guide [7.7]</a></span>
»
<span class="breadcrumb-link"><a href="rest-apis.html">REST APIs</a></span>
»
<span class="breadcrumb-link"><a href="ml-df-analytics-apis.html">Machine learning data frame analytics APIs</a></span>
»
<span class="breadcrumb-node">Get data frame analytics jobs statistics API</span>
</div>
<div class="navheader">
<span class="prev">
<a href="get-dfanalytics.html">« Get data frame analytics jobs API</a>
</span>
<span class="next">
<a href="get-inference.html">Get inference trained model API »</a>
</span>
</div>
<div class="section xpack">
<div class="titlepage"><div><div>
<h2 class="title">
<a id="get-dfanalytics-stats"></a>Get data frame analytics jobs statistics API<a class="edit_me edit_me_private" rel="nofollow" title="Editing on GitHub is available to Elastic" href="https://github.com/elastic/elasticsearch/edit/7.7/docs/reference/ml/df-analytics/apis/get-dfanalytics-stats.asciidoc">edit</a><a class="xpack_tag" href="https://www.elastic.co/subscriptions"></a>
</h2>
</div></div></div>

<p>Retrieves usage information for data frame analytics jobs.</p>
<div class="warning admon">
<div class="icon"></div>
<div class="admon_content">
<p>This functionality is experimental and may be changed or removed completely in a future release. Elastic will take a best effort approach to fix any issues, but experimental features are not subject to the support SLA of official GA features.</p>
</div>
</div>
<div class="section">
<div class="titlepage"><div><div>
<h3 class="title">
<a id="ml-get-dfanalytics-stats-request"></a>Request<a class="edit_me edit_me_private" rel="nofollow" title="Editing on GitHub is available to Elastic" href="https://github.com/elastic/elasticsearch/edit/7.7/docs/reference/ml/df-analytics/apis/get-dfanalytics-stats.asciidoc">edit</a>
</h3>
</div></div></div>
<p><code class="literal">GET _ml/data_frame/analytics/&lt;data_frame_analytics_id&gt;/_stats</code><br></p>
<p><code class="literal">GET _ml/data_frame/analytics/&lt;data_frame_analytics_id&gt;,&lt;data_frame_analytics_id&gt;/_stats</code><br></p>
<p><code class="literal">GET _ml/data_frame/analytics/_stats</code><br></p>
<p><code class="literal">GET _ml/data_frame/analytics/_all/_stats</code><br></p>
<p><code class="literal">GET _ml/data_frame/analytics/*/_stats</code></p>
</div>

<div class="section">
<div class="titlepage"><div><div>
<h3 class="title">
<a id="ml-get-dfanalytics-stats-prereq"></a>Prerequisites<a class="edit_me edit_me_private" rel="nofollow" title="Editing on GitHub is available to Elastic" href="https://github.com/elastic/elasticsearch/edit/7.7/docs/reference/ml/df-analytics/apis/get-dfanalytics-stats.asciidoc">edit</a>
</h3>
</div></div></div>
<p>If the Elasticsearch security features are enabled, you must have the following privileges:</p>
<div class="ulist itemizedlist">
<ul class="itemizedlist">
<li class="listitem">
cluster: <code class="literal">monitor_ml</code>
</li>
</ul>
</div>
<p>For more information, see <a class="xref" href="security-privileges.html" title="Security privileges">Security privileges</a> and <a class="xref" href="built-in-roles.html" title="Built-in roles">Built-in roles</a>.</p>
</div>

<div class="section">
<div class="titlepage"><div><div>
<h3 class="title">
<a id="ml-get-dfanalytics-stats-path-params"></a>Path parameters<a class="edit_me edit_me_private" rel="nofollow" title="Editing on GitHub is available to Elastic" href="https://github.com/elastic/elasticsearch/edit/7.7/docs/reference/ml/df-analytics/apis/get-dfanalytics-stats.asciidoc">edit</a>
</h3>
</div></div></div>
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">&lt;data_frame_analytics_id&gt;</code>
</span>
</dt>
<dd>
(Optional, string)
Identifier for the data frame analytics job. If you do not specify this option, the API
returns information for the first hundred data frame analytics jobs.
</dd>
</dl>
</div>
</div>

<div class="section">
<div class="titlepage"><div><div>
<h3 class="title">
<a id="ml-get-dfanalytics-stats-query-params"></a>Query parameters<a class="edit_me edit_me_private" rel="nofollow" title="Editing on GitHub is available to Elastic" href="https://github.com/elastic/elasticsearch/edit/7.7/docs/reference/ml/df-analytics/apis/get-dfanalytics-stats.asciidoc">edit</a>
</h3>
</div></div></div>
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">allow_no_match</code>
</span>
</dt>
<dd>
<p>
(Optional, boolean)
 Specifies what to do when the request:
</p>
<div class="ulist itemizedlist">
<ul class="itemizedlist">
<li class="listitem">
Contains wildcard expressions and there are no data frame analytics jobs that match.
</li>
<li class="listitem">
Contains the <code class="literal">_all</code> string or no identifiers and there are no matches.
</li>
<li class="listitem">
Contains wildcard expressions and there are only partial matches.
</li>
</ul>
</div>
<p>The default value is <code class="literal">true</code>, which returns an empty <code class="literal">data_frame_analytics</code> array
when there are no matches and the subset of results when there are partial
matches. If this parameter is <code class="literal">false</code>, the request returns a <code class="literal">404</code> status code
when there are no matches or only partial matches.</p>
</dd>
<dt>
<span class="term">
<code class="literal">from</code>
</span>
</dt>
<dd>
(Optional, integer)
Skips the specified number of data frame analytics jobs. The default value is <code class="literal">0</code>.
</dd>
<dt>
<span class="term">
<code class="literal">size</code>
</span>
</dt>
<dd>
(Optional, integer)
Specifies the maximum number of data frame analytics jobs to obtain. The default value
is <code class="literal">100</code>.
</dd>
</dl>
</div>
</div>

<div class="section child_attributes">
<div class="titlepage"><div><div>
<h3 class="title">
<a id="ml-get-dfanalytics-stats-response-body"></a>Response body<a class="edit_me edit_me_private" rel="nofollow" title="Editing on GitHub is available to Elastic" href="https://github.com/elastic/elasticsearch/edit/7.7/docs/reference/ml/df-analytics/apis/get-dfanalytics-stats.asciidoc">edit</a>
</h3>
</div></div></div>
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">data_frame_analytics</code>
</span>
</dt>
<dd>
<p>
(array)
An array of objects that contain usage information for data frame analytics jobs, which
are sorted by the <code class="literal">id</code> value in ascending order.
</p>
<details open>
<summary class="title">Properties of data frame analytics job usage resources</summary>
<div class="content">
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">analysis_stats</code>
</span>
</dt>
<dd>
<p>
(object)
An object containing information about the analysis job.
</p>
<details open>
<summary class="title">Properties of <code class="literal">analysis_stats</code></summary>
<div class="content">
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">classification_stats</code>
</span>
</dt>
<dd>
<p>
(object)
An object containing information about the classification analysis job.
</p>
<details open>
<summary class="title">Properties of <code class="literal">classification_stats</code></summary>
<div class="content">
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">hyperparameters</code>
</span>
</dt>
<dd>
<p>
(object)
An object containing the parameters of the classification analysis job.
</p>
<details open>
<summary class="title">Properties of <code class="literal">hyperparameters</code></summary>
<div class="content">
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">alpha</code>
</span>
</dt>
<dd>
(double)
Regularization factor to penalize deeper trees when training decision trees.
</dd>
<dt>
<span class="term">
<code class="literal">class_assignment_objective</code>
</span>
</dt>
<dd>
(string)
Defines the objective to optimize when assigning class labels:
<code class="literal">maximize_accuracy</code> or <code class="literal">maximize_minimum_recall</code>. When maximizing accuracy,
class labels are chosen to maximize the number of correct predictions. When
maximizing minimum recall, labels are chosen to maximize the minimum recall
for any class. Defaults to <code class="literal">maximize_minimum_recall</code>.
</dd>
<dt>
<span class="term">
<code class="literal">downsample_factor</code>
</span>
</dt>
<dd>
(double)
The value of the downsample factor.
</dd>
<dt>
<span class="term">
<code class="literal">eta</code>
</span>
</dt>
<dd>
(double)
Advanced configuration option. The shrinkage applied to the weights. Smaller
values result in larger forests which have a better generalization error.
However, the smaller the value the longer the training will take. For more
information, about shrinkage, see
<a href="https://en.wikipedia.org/wiki/Gradient_boosting#Shrinkage" class="ulink" target="_top">this wiki article</a>.
</dd>
<dt>
<span class="term">
<code class="literal">eta_growth_rate_per_tree</code>
</span>
</dt>
<dd>
(double)
Specifies the rate at which the <code class="literal">eta</code> increases for each new tree that is added to the
forest. For example, a rate of <code class="literal">1.05</code> increases <code class="literal">eta</code> by 5%.
</dd>
<dt>
<span class="term">
<code class="literal">feature_bag_fraction</code>
</span>
</dt>
<dd>
(double)
Advanced configuration option. Defines the fraction of features that will be
used when selecting a random bag for each candidate split. By default, this
value is calculated during hyperparameter optimization.
</dd>
<dt>
<span class="term">
<code class="literal">gamma</code>
</span>
</dt>
<dd>
(double)
Advanced configuration option. Regularization parameter to prevent overfitting
on the training data set. Multiplies a linear penalty associated with the size of
individual trees in the forest. The higher the value the more training will
prefer smaller trees. The smaller this parameter the larger individual trees
will be and the longer training will take. By default, this value is calculated
during hyperparameter optimization.
</dd>
<dt>
<span class="term">
<code class="literal">lambda</code>
</span>
</dt>
<dd>
(double)
Advanced configuration option. Regularization parameter to prevent overfitting
on the training data set. Multiplies an L2 regularisation term which applies to
leaf weights of the individual trees in the forest. The higher the value the
more training will attempt to keep leaf weights small. This makes the prediction
function smoother at the expense of potentially not being able to capture
relevant relationships between the features and the dependent variable. The smaller this
parameter the larger individual trees will be and the longer training will take.
By default, this value is calculated during hyperparameter optimization.
</dd>
<dt>
<span class="term">
<code class="literal">max_attempts_to_add_tree</code>
</span>
</dt>
<dd>
(integer)
If the algorithm fails to determine a non-trivial tree (more than a single
leaf), this parameter determines how many of such consecutive failures are
tolerated. Once the number of attempts exceeds the threshold, the forest
training stops.
</dd>
<dt>
<span class="term">
<code class="literal">max_optimization_rounds_per_hyperparameter</code>
</span>
</dt>
<dd>
(integer)
A multiplier responsible for determining the maximum number of
hyperparameter optimization steps in the Bayesian optimization procedure.
The maximum number of steps is determined based on the number of undefined hyperparameters
times the maximum optimization rounds per hyperparameter.
</dd>
<dt>
<span class="term">
<code class="literal">max_trees</code>
</span>
</dt>
<dd>
(integer)
Advanced configuration option. Defines the maximum number of trees the forest is
allowed to contain. The maximum value is 2000. By default, this value is
calculated during hyperparameter optimization.
</dd>
<dt>
<span class="term">
<code class="literal">num_folds</code>
</span>
</dt>
<dd>
(integer)
The maximum number of folds for the cross-validation procedure.
</dd>
<dt>
<span class="term">
<code class="literal">num_splits_per_feature</code>
</span>
</dt>
<dd>
(integer)
Determines the maximum number of splits for every feature that can occur in a
decision tree when the tree is trained.
</dd>
<dt>
<span class="term">
<code class="literal">soft_tree_depth_limit</code>
</span>
</dt>
<dd>
(double)
Tree depth limit is used for calculating the tree depth penalty. This is a soft
limit, it can be exceeded.
</dd>
<dt>
<span class="term">
<code class="literal">soft_tree_depth_tolerance</code>
</span>
</dt>
<dd>
(double)
Tree depth tolerance is used for calculating the tree depth penalty. This is a
soft limit, it can be exceeded.
</dd>
</dl>
</div>
</div>
</details>
</dd>
<dt>
<span class="term">
<code class="literal">iteration</code>
</span>
</dt>
<dd>
(integer)
The number of iterations on the analysis.
</dd>
<dt>
<span class="term">
<code class="literal">timestamp</code>
</span>
</dt>
<dd>
(date)
The timestamp when the statistics were reported in milliseconds since the epoch.
</dd>
</dl>
</div>
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">timing_stats</code>
</span>
</dt>
<dd>
<p>
(object)
An object containing time statistics about the data frame analytics job.
</p>
<details open>
<summary class="title">Properties of <code class="literal">timing_stats</code></summary>
<div class="content">
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">elapsed_time</code>
</span>
</dt>
<dd>
(integer)
Runtime of the analysis in milliseconds.
</dd>
<dt>
<span class="term">
<code class="literal">iteration_time</code>
</span>
</dt>
<dd>
(integer)
Runtime of the latest iteration of the analysis in milliseconds.
</dd>
</dl>
</div>
</div>
</details>
</dd>
</dl>
</div>
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">validation_loss</code>
</span>
</dt>
<dd>
<p>
(object)
An object containing information about validation loss.
</p>
<details open>
<summary class="title">Properties of <code class="literal">validation_loss</code></summary>
<div class="content">
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">fold_values</code>
</span>
</dt>
<dd>
(array of strings)
Validation loss values for every added decision tree during the forest growing
procedure.
</dd>
<dt>
<span class="term">
<code class="literal">loss_type</code>
</span>
</dt>
<dd>
(string)
The type of the loss metric. For example, <code class="literal">binomial_logistic</code>.
</dd>
</dl>
</div>
</div>
</details>
</dd>
</dl>
</div>
</div>
</details>
</dd>
</dl>
</div>
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">outlier_detection_stats</code>
</span>
</dt>
<dd>
<p>
(object)
An object containing information about the outlier detection job.
</p>
<details open>
<summary class="title">Properties of <code class="literal">outlier_detection_stats</code></summary>
<div class="content">
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">parameters</code>
</span>
</dt>
<dd>
<p>
(object)
The list of job parameters specified by the user or determined by algorithmic
heuristics.
</p>
<details open>
<summary class="title">Properties of <code class="literal">parameters</code></summary>
<div class="content">
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">compute_feature_influence</code>
</span>
</dt>
<dd>
(boolean)
Specifies whether the feature influence calculation is enabled. Defaults to
<code class="literal">true</code>.
</dd>
<dt>
<span class="term">
<code class="literal">feature_influence_threshold</code>
</span>
</dt>
<dd>
(double)
The minimum outlier score that a document needs to have in order to calculate its
feature influence score. Value range: 0-1 (<code class="literal">0.1</code> by default).
</dd>
<dt>
<span class="term">
<code class="literal">method</code>
</span>
</dt>
<dd>
(string)
The method that outlier detection uses. Available methods are <code class="literal">lof</code>, <code class="literal">ldof</code>,
<code class="literal">distance_kth_nn</code>, <code class="literal">distance_knn</code>, and <code class="literal">ensemble</code>. The default value is
<code class="literal">ensemble</code>, which means that outlier detection uses an ensemble of different methods
and normalises and combines their individual outlier scores to obtain the overall
outlier score.
</dd>
<dt>
<span class="term">
<code class="literal">n_neighbors</code>
</span>
</dt>
<dd>
(integer)
Defines the value for how many nearest neighbors each method of outlier detection
uses to calculate its outlier score. When the value is not set, different values are
used for different ensemble members. This default behavior helps improve the
diversity in the ensemble; only override it if you are confident that the value
you choose is appropriate for the data set.
</dd>
<dt>
<span class="term">
<code class="literal">outlier_fraction</code>
</span>
</dt>
<dd>
(double)
The proportion of the data set that is assumed to be outlying prior to
outlier detection. For example, 0.05 means it is assumed that 5% of values are real
outliers and 95% are inliers.
</dd>
</dl>
</div>
<p>The proportion of the data set that is assumed to be outlying prior to
outlier detection.</p>
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">standardization_enabled</code>
</span>
</dt>
<dd>
(boolean)
If <code class="literal">true</code>, the following operation is performed on the columns before computing
outlier scores: (x_i - mean(x_i)) / sd(x_i). Defaults to <code class="literal">true</code>. For more
information about this concept, see
<a href="https://en.wikipedia.org/wiki/Feature_scaling#Standardization_(Z-score_Normalization)" class="ulink" target="_top">Wikipedia</a>.
</dd>
</dl>
</div>
</div>
</details>
</dd>
<dt>
<span class="term">
<code class="literal">timestamp</code>
</span>
</dt>
<dd>
(date)
The timestamp when the statistics were reported in milliseconds since the epoch.
</dd>
</dl>
</div>
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">timing_stats</code>
</span>
</dt>
<dd>
<p>
(object)
An object containing time statistics about the data frame analytics job.
</p>
<details open>
<summary class="title">Property of <code class="literal">timing_stats</code></summary>
<div class="content">
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">elapsed_time</code>
</span>
</dt>
<dd>
(integer)
Runtime of the analysis in milliseconds.
</dd>
</dl>
</div>
</div>
</details>
</dd>
</dl>
</div>
</div>
</details>
</dd>
</dl>
</div>
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">regression_stats</code>
</span>
</dt>
<dd>
<p>
(object)
An object containing information about the regression analysis job.
</p>
<details open>
<summary class="title">Properties of <code class="literal">regression_stats</code></summary>
<div class="content">
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">hyperparameters</code>
</span>
</dt>
<dd>
<p>
(object)
An object containing the parameters of the regression analysis job.
</p>
<details open>
<summary class="title">Properties of <code class="literal">hyperparameters</code></summary>
<div class="content">
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">alpha</code>
</span>
</dt>
<dd>
(double)
Regularization factor to penalize deeper trees when training decision trees.
</dd>
<dt>
<span class="term">
<code class="literal">downsample_factor</code>
</span>
</dt>
<dd>
(double)
The value of the downsample factor.
</dd>
<dt>
<span class="term">
<code class="literal">eta</code>
</span>
</dt>
<dd>
(double)
Advanced configuration option. The shrinkage applied to the weights. Smaller
values result in larger forests which have a better generalization error.
However, the smaller the value the longer the training will take. For more
information, about shrinkage, see
<a href="https://en.wikipedia.org/wiki/Gradient_boosting#Shrinkage" class="ulink" target="_top">this wiki article</a>.
</dd>
<dt>
<span class="term">
<code class="literal">eta_growth_rate_per_tree</code>
</span>
</dt>
<dd>
(double)
Specifies the rate at which the <code class="literal">eta</code> increases for each new tree that is added to the
forest. For example, a rate of <code class="literal">1.05</code> increases <code class="literal">eta</code> by 5%.
</dd>
<dt>
<span class="term">
<code class="literal">feature_bag_fraction</code>
</span>
</dt>
<dd>
(double)
Advanced configuration option. Defines the fraction of features that will be
used when selecting a random bag for each candidate split. By default, this
value is calculated during hyperparameter optimization.
</dd>
<dt>
<span class="term">
<code class="literal">gamma</code>
</span>
</dt>
<dd>
(double)
Advanced configuration option. Regularization parameter to prevent overfitting
on the training data set. Multiplies a linear penalty associated with the size of
individual trees in the forest. The higher the value the more training will
prefer smaller trees. The smaller this parameter the larger individual trees
will be and the longer training will take. By default, this value is calculated
during hyperparameter optimization.
</dd>
<dt>
<span class="term">
<code class="literal">lambda</code>
</span>
</dt>
<dd>
(double)
Advanced configuration option. Regularization parameter to prevent overfitting
on the training data set. Multiplies an L2 regularisation term which applies to
leaf weights of the individual trees in the forest. The higher the value the
more training will attempt to keep leaf weights small. This makes the prediction
function smoother at the expense of potentially not being able to capture
relevant relationships between the features and the dependent variable. The smaller this
parameter the larger individual trees will be and the longer training will take.
By default, this value is calculated during hyperparameter optimization.
</dd>
<dt>
<span class="term">
<code class="literal">max_attempts_to_add_tree</code>
</span>
</dt>
<dd>
(integer)
If the algorithm fails to determine a non-trivial tree (more than a single
leaf), this parameter determines how many of such consecutive failures are
tolerated. Once the number of attempts exceeds the threshold, the forest
training stops.
</dd>
<dt>
<span class="term">
<code class="literal">max_optimization_rounds_per_hyperparameter</code>
</span>
</dt>
<dd>
(integer)
A multiplier responsible for determining the maximum number of
hyperparameter optimization steps in the Bayesian optimization procedure.
The maximum number of steps is determined based on the number of undefined hyperparameters
times the maximum optimization rounds per hyperparameter.
</dd>
<dt>
<span class="term">
<code class="literal">max_trees</code>
</span>
</dt>
<dd>
(integer)
Advanced configuration option. Defines the maximum number of trees the forest is
allowed to contain. The maximum value is 2000. By default, this value is
calculated during hyperparameter optimization.
</dd>
<dt>
<span class="term">
<code class="literal">num_folds</code>
</span>
</dt>
<dd>
(integer)
The maximum number of folds for the cross-validation procedure.
</dd>
<dt>
<span class="term">
<code class="literal">num_splits_per_feature</code>
</span>
</dt>
<dd>
(integer)
Determines the maximum number of splits for every feature that can occur in a
decision tree when the tree is trained.
</dd>
<dt>
<span class="term">
<code class="literal">soft_tree_depth_limit</code>
</span>
</dt>
<dd>
(double)
Tree depth limit is used for calculating the tree depth penalty. This is a soft
limit, it can be exceeded.
</dd>
<dt>
<span class="term">
<code class="literal">soft_tree_depth_tolerance</code>
</span>
</dt>
<dd>
(double)
Tree depth tolerance is used for calculating the tree depth penalty. This is a
soft limit, it can be exceeded.
</dd>
</dl>
</div>
</div>
</details>
</dd>
<dt>
<span class="term">
<code class="literal">iteration</code>
</span>
</dt>
<dd>
(integer)
The number of iterations on the analysis.
</dd>
<dt>
<span class="term">
<code class="literal">timestamp</code>
</span>
</dt>
<dd>
(date)
The timestamp when the statistics were reported in milliseconds since the epoch.
</dd>
</dl>
</div>
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">timing_stats</code>
</span>
</dt>
<dd>
<p>
(object)
An object containing time statistics about the data frame analytics job.
</p>
<details open>
<summary class="title">Propertis of <code class="literal">timing_stats</code></summary>
<div class="content">
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">elapsed_time</code>
</span>
</dt>
<dd>
(integer)
Runtime of the analysis in milliseconds.
</dd>
<dt>
<span class="term">
<code class="literal">iteration_time</code>
</span>
</dt>
<dd>
(integer)
Runtime of the latest iteration of the analysis in milliseconds.
</dd>
</dl>
</div>
</div>
</details>
</dd>
</dl>
</div>
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">validation_loss</code>
</span>
</dt>
<dd>
<p>
(object)
An object containing information about validation loss.
</p>
<details open>
<summary class="title">Properties of <code class="literal">validation_loss</code></summary>
<div class="content">
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">fold_values</code>
</span>
</dt>
<dd>
(array of strings)
Validation loss values for every added decision tree during the forest growing
procedure.
</dd>
<dt>
<span class="term">
<code class="literal">loss_type</code>
</span>
</dt>
<dd>
(string)
The type of the loss metric. For example, <code class="literal">binomial_logistic</code>.
</dd>
</dl>
</div>
</div>
</details>
</dd>
</dl>
</div>
</div>
</details>
</dd>
</dl>
</div>
</div>
</details>
</dd>
<dt>
<span class="term">
<code class="literal">assignment_explanation</code>
</span>
</dt>
<dd>
(string)
For running jobs only, contains messages relating to the selection of a node to
run the job.
</dd>
</dl>
</div>
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">data_counts</code>
</span>
</dt>
<dd>
<p>
(object)
An object that provides counts for the quantity of documents skipped, used in
training, or available for testing.
</p>
<details open>
<summary class="title">Properties of <code class="literal">data_counts</code></summary>
<div class="content">
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">skipped_docs_count</code>
</span>
</dt>
<dd>
(integer)
The number of documents that are skipped during the analysis because they
contained values that are not supported by the analysis. For example,
outlier detection does not support missing fields so it skips documents with missing
fields. Likewise, all types of analysis skip documents that contain arrays with
more than one element.
</dd>
<dt>
<span class="term">
<code class="literal">test_docs_count</code>
</span>
</dt>
<dd>
(integer)
The number of documents that are not used for training the model and can be used
for testing.
</dd>
<dt>
<span class="term">
<code class="literal">training_docs_count</code>
</span>
</dt>
<dd>
(integer)
The number of documents that are used for training the model.
</dd>
</dl>
</div>
</div>
</details>
</dd>
<dt>
<span class="term">
<code class="literal">id</code>
</span>
</dt>
<dd>
(string)
The unique identifier of the data frame analytics job.
</dd>
<dt>
<span class="term">
<code class="literal">memory_usage</code>
</span>
</dt>
<dd>
<p>
(Optional, object)
An object describing memory usage of the analytics. It is present only after the
job is started and memory usage is reported.
</p>
<details open>
<summary class="title">Properties of <code class="literal">memory_usage</code></summary>
<div class="content">
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">peak_usage_bytes</code>
</span>
</dt>
<dd>
(long)
The number of bytes used at the highest peak of memory usage.
</dd>
<dt>
<span class="term">
<code class="literal">timestamp</code>
</span>
</dt>
<dd>
(date)
The timestamp when memory usage was calculated.
</dd>
</dl>
</div>
</div>
</details>
</dd>
<dt>
<span class="term">
<code class="literal">node</code>
</span>
</dt>
<dd>
<p>
(object)
Contains properties for the node that runs the job. This information is
available only for running jobs.
</p>
<details open>
<summary class="title">Properties of <code class="literal">node</code></summary>
<div class="content">
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">attributes</code>
</span>
</dt>
<dd>
(object)
Lists node attributes such as <code class="literal">ml.machine_memory</code> or <code class="literal">ml.max_open_jobs</code> settings.
</dd>
<dt>
<span class="term">
<code class="literal">ephemeral_id</code>
</span>
</dt>
<dd>
(string)
The ephemeral ID of the node.
</dd>
<dt>
<span class="term">
<code class="literal">id</code>
</span>
</dt>
<dd>
(string)
The unique identifier of the node.
</dd>
<dt>
<span class="term">
<code class="literal">name</code>
</span>
</dt>
<dd>
(string)
The node name.
</dd>
<dt>
<span class="term">
<code class="literal">transport_address</code>
</span>
</dt>
<dd>
(string)
The host and port where transport HTTP connections are accepted.
</dd>
</dl>
</div>
</div>
</details>
</dd>
<dt>
<span class="term">
<code class="literal">progress</code>
</span>
</dt>
<dd>
<p>
(array) The progress report of the data frame analytics job by phase.
</p>
<details open>
<summary class="title">Properties of phase objects</summary>
<div class="content">
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">phase</code>
</span>
</dt>
<dd>
(string) Defines the phase of the data frame analytics job. Possible phases:
<code class="literal">reindexing</code>, <code class="literal">loading_data</code>, <code class="literal">analyzing</code>, and <code class="literal">writing_results</code>.
</dd>
<dt>
<span class="term">
<code class="literal">progress_percent</code>
</span>
</dt>
<dd>
(integer) The progress that the data frame analytics job has made expressed in
percentage.
</dd>
</dl>
</div>
</div>
</details>
</dd>
<dt>
<span class="term">
<code class="literal">state</code>
</span>
</dt>
<dd>
(string) The status of the data frame analytics job, which can be one of the following
values: <code class="literal">analyzing</code>, <code class="literal">failed</code>, <code class="literal">reindexing</code>, <code class="literal">started</code>, <code class="literal">starting</code>, <code class="literal">stopped</code>,
<code class="literal">stopping</code>.
</dd>
</dl>
</div>
</div>
</details>
</dd>
</dl>
</div>
</div>

<div class="section">
<div class="titlepage"><div><div>
<h3 class="title">
<a id="ml-get-dfanalytics-stats-response-codes"></a>Response codes<a class="edit_me edit_me_private" rel="nofollow" title="Editing on GitHub is available to Elastic" href="https://github.com/elastic/elasticsearch/edit/7.7/docs/reference/ml/df-analytics/apis/get-dfanalytics-stats.asciidoc">edit</a>
</h3>
</div></div></div>
<div class="variablelist">
<dl class="variablelist">
<dt>
<span class="term">
<code class="literal">404</code> (Missing resources)
</span>
</dt>
<dd>
If <code class="literal">allow_no_match</code> is <code class="literal">false</code>, this code indicates that there are no
resources that match the request or only partial matches for the request.
</dd>
</dl>
</div>
</div>

<div class="section">
<div class="titlepage"><div><div>
<h3 class="title">
<a id="ml-get-dfanalytics-stats-example"></a>Examples<a class="edit_me edit_me_private" rel="nofollow" title="Editing on GitHub is available to Elastic" href="https://github.com/elastic/elasticsearch/edit/7.7/docs/reference/ml/df-analytics/apis/get-dfanalytics-stats.asciidoc">edit</a>
</h3>
</div></div></div>
<p>The following API retrieves usage information for the
<a href="https://www.elastic.co/guide/en/machine-learning/7.7/ecommerce-outliers.html" class="ulink" target="_top">outlier detection data frame analytics job example</a>:</p>
<div class="pre_wrapper lang-console">
<pre class="programlisting prettyprint lang-console">GET _ml/data_frame/analytics/ecommerce/_stats</pre>
</div>
<div class="console_widget" data-snippet="snippets/1858.console"></div>
<p>The API returns the following results:</p>
<div class="pre_wrapper lang-console-result">
<pre class="programlisting prettyprint lang-console-result">{
  "count" : 1,
  "data_frame_analytics" : [
    {
      "id" : "ecommerce",
      "state" : "stopped",
      "progress" : [
        {
          "phase" : "reindexing",
          "progress_percent" : 100
        },
        {
          "phase" : "loading_data",
          "progress_percent" : 100
        },
        {
          "phase" : "analyzing",
          "progress_percent" : 100
        },
        {
          "phase" : "writing_results",
          "progress_percent" : 100
        }
      ],
      "data_counts" : {
        "training_docs_count" : 3321,
        "test_docs_count" : 0,
        "skipped_docs_count" : 0
      },
      "memory_usage" : {
        "timestamp" : 1586905058000,
        "peak_usage_bytes" : 279484
      },
      "analysis_stats" : {
        "outlier_detection_stats" : {
          "timestamp" : 1586905058000,
          "parameters" : {
            "n_neighbors" : 0,
            "method" : "ensemble",
            "compute_feature_influence" : true,
            "feature_influence_threshold" : 0.1,
            "outlier_fraction" : 0.05,
            "standardization_enabled" : true
          },
          "timing_stats" : {
            "elapsed_time" : 245
          }
        }
      }
    }
  ]
}</pre>
</div>
</div>

</div>
<div class="navfooter">
<span class="prev">
<a href="get-dfanalytics.html">« Get data frame analytics jobs API</a>
</span>
<span class="next">
<a href="get-inference.html">Get inference trained model API »</a>
</span>
</div>
</div>

                  <!-- end body -->
                        </div>
                        <div class="col-xs-12 col-sm-4 col-md-4" id="right_col">
                        
                        </div>
                    </div>
                </div>
            </section>
        </div>
    </section>
</div>
<script src="../static/cn.js"></script>
</body>
</html>